<?php

namespace Biz\Mailers\User\Tags;

use Biz\Models\User\User;
use Biz\Mailers\MailerTags;

/**
 * UserTags.
 *
 * @license [http://www.85do.com] [杭州永奥网络科技有限公司]
 * @copyright Copyright (c) 2018-2026 Hangzhou Yongao Technology Co., Ltd. All rights reserved.
 */
class UserTags extends MailerTags
{
    /**
     * @var \Biz\Models\User\User
     */
    protected $user;

    /**
     * SiteTags constructor.
     *
     * @param User $user
     */
    public function __construct(User $user)
    {
        $this->user = $user;
        $this->supportTags();
    }

    /**
     * Support Tags.
     */
    public function supportTags(): void
    {
        $this->tags['UserName'] = $this->user->username;
        $this->tags['NickName'] = $this->user->nickname;
    }
}
